package com.baidu.disconf.web.service.config.bo;

import com.baidu.dsp.common.dao.Columns;
import com.baidu.dsp.common.dao.DB;
import com.baidu.unbiz.common.genericdao.annotation.Column;
import com.baidu.unbiz.common.genericdao.annotation.Table;
import com.github.knightliao.apollo.db.bo.BaseObject;

/**
 * @author dengxiang
 * @version 2014-6-16
 */
@Table(db = DB.DB_NAME, name = "config_history",keyColumn = "history_id")
public class ConfigHistory extends BaseObject<Long> {

    /**
     *
     */
    private static final long serialVersionUID = -2217832889126331665L;
    
    /**
     *Config主键
     */
    @Column(value = Columns.CONFIG_ID)
    private Long configId;
    /**
     *配置类型
     */
    @Column(value = Columns.TYPE)
    private Integer type;

    /**
     *配置名称
     */
    @Column(value = Columns.NAME)
    private String name;

    /**
     *配置内容
     */
    @Column(value = Columns.VALUE)
    private String value;

    /**
     *应用id
     */
    @Column(value = Columns.APP_ID)
    private Long appId;

    /**
     *版本
     */
    @Column(value = Columns.VERSION)
    private String version;

    /**
     *环境id
     */
    @Column(value = Columns.ENV_ID)
    private Long envId;

    /**
     * 创建时间
     */
    @Column(value = Columns.CREATE_TIME)
    private String createTime;

    /**
     * 更新时间
     */
    @Column(value = Columns.UPDATE_TIME)
    private String updateTime;
    
    /**
     * 租户
     */
    @Column(value = "bank_key")
    private String bankKey;
    
    /**
     * 更新时间
     */
    @Column(value = "user_id")
    private String userId;

    /**
     * 动作
     */
    @Column(value = "action")
    private String action;
    
    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getValue() {
        return value;
    }

    public void setValue(String value) {
        this.value = value;
    }

    public Long getAppId() {
        return appId;
    }

    public void setAppId(Long appId) {
        this.appId = appId;
    }

    public String getVersion() {
        return version;
    }

    public void setVersion(String version) {
        this.version = version;
    }

    public Long getEnvId() {
        return envId;
    }

    public void setEnvId(Long envId) {
        this.envId = envId;
    }

    public String getCreateTime() {
        return createTime;
    }

    public void setCreateTime(String createTime) {
        this.createTime = createTime;
    }

    public String getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(String updateTime) {
        this.updateTime = updateTime;
    }

    public String getBankKey() {
		return bankKey;
	}

	public void setBankKey(String bankKey) {
		this.bankKey = bankKey;
	}

	public String getUserId() {
		return userId;
	}

	public void setUserId(String userId) {
		this.userId = userId;
	}

	public Long getConfigId() {
		return configId;
	}

	public void setConfigId(Long config_id) {
		this.configId = config_id;
	}
	
	public String getAction() {
		return action;
	}

	public void setAction(String action) {
		this.action = action;
	}

	@Override
    public String toString() {
        return "ConfigHistory [type=" + type + ", configId="+configId+", name=" + name + ", value=" + value + ", appId=" + appId + ", version=" +
                   version + ", envId=" + envId + ", createTime=" + createTime + ", updateTime=" + updateTime +
                   ", bankKey=" + bankKey+", userId=" + userId+ "]";
    }
}
